//
//  File.swift
//
//
//  Created by didi on 2022/9/14.
//

import MolecularObjects
import Vapor

public extension Request {
    func getUserAccount() throws -> MUser {
        guard let user = auth.get(MUser.self) else {
            throw Abort(.forbidden)
        }
        return user
    }
}
